import request from '@/utils/request'

//  获取住院科室列表
export function getDepartmentListAPI(obj) {
    return request({
      url: '/department',
      method: 'GET',
      params: obj
    })
  }

  //  新增
export function addDepartmentAPI(obj) {
    return request({
      url: '/department',
      method: 'POST',
      data: obj
    })
  }
  
  export function delDepartmentAPI(id) {
    return request({
      url: '/department/' + id,
      method: 'DELETE'
    })
  }
  
  export function editDepartmentAPI(obj) {
    return request({
      url: '/department',
      method: 'PUT',
      data: obj
    })
  }


//  获取药品列表
export function getMedicineListAPI(obj) {
    return request({
      url: '/medicine',
      method: 'GET',
      params: obj
    })
  }

  //  新增
export function addMedicineAPI(obj) {
    return request({
      url: '/medicine',
      method: 'POST',
      data: obj
    })
  }
  
  export function delMedicineAPI(id) {
    return request({
      url: '/medicine/' + id,
      method: 'DELETE'
    })
  }
  
  export function editMedicineAPI(obj) {
    return request({
      url: '/medicine',
      method: 'PUT',
      data: obj
    })
  }

//  获取医生列表
export function getDoctorListAPI(obj) {
    return request({
      url: '/doctor',
      method: 'GET',
      params: obj
    })
  }

  //  新增
export function addDoctorAPI(obj) {
    return request({
      url: '/doctor',
      method: 'POST',
      data: obj
    })
  }
  
  export function delDoctorAPI(doctorID) {
    return request({
      url: '/doctor/' + doctorID,
      method: 'DELETE'
    })
  }
  
  export function editDoctorAPI(obj) {
    return request({
      url: '/doctor',
      method: 'PUT',
      data: obj
    })
  }  
//  获取收费员列表
export function getClerkListAPI(obj) {
    return request({
      url: '/clerk',
      method: 'GET',
      params: obj
    })
  }

  //  新增
export function addClerkAPI(obj) {
    return request({
      url: '/clerk',
      method: 'POST',
      data: obj
    })
  }
  
  export function delClerkAPI(clerkID) {
    return request({
      url: '/clerk/' + clerkID,
      method: 'DELETE'
    })
  }
  
  export function editClerkAPI(obj) {
    return request({
      url: '/clerk',
      method: 'PUT',
      data: obj
    })
  }  
